package org.zzz.service;

import org.zzz.entity.StudentVo;
import org.zzz.entity.User;
import org.zzz.entity.TeacherVo;
import org.zzz.entity.vo.StudentShowVo;

import java.util.List;

/**
 * @Author ZZF
 * @Time 2021/04/19 15:55
 */
public interface UserService {

    List<User> getUser();

    /**
     * 登录
     * @param username
     * @param password
     * @return
     */
    User login(String username,String password);

    /**
     * 添加用户信息
     * @param user
     * @return
     */
    boolean insertUser(User user);

    User getUserByUsername(String username);

    /**
     * 删除用户信息，flag1为学生，2为老师
     * @param username
     * @param flag
     * @return
     */
    boolean deleteUser(String username,int flag);

    TeacherVo getTeacherById(String username);

    StudentVo getStudentById(String username);

    boolean updateTeacher(TeacherVo teacherVo);

    boolean updateStudent(StudentVo studentVo);

    boolean updateUserById(String sourceId,String targetId);


}
